#include <memory>
#include <iostream>

using namespace std;

struct Base
{
    Base(){ cout << "Base construct...\n"; }
    Base(int a){  };
    /* data */
};

struct Son:Base
{
    Son(){ cout << "Son construct...\n"; }
    Son(int a){ cout << "Son construct with int a...\n"; }
};

int main(){
    // array
    std::unique_ptr<Base[]> p{new Base[3]};
    std::unique_ptr<Base[]> p1(new Base[3]);
    // inherit
    std::unique_ptr<Base> pp(new Son);
    std::unique_ptr<Base> ppp = std::make_unique<Son>();

    return EXIT_SUCCESS;
}
